package com.umbr3lla.ui.test;

import java.awt.Graphics;
import java.awt.Image;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;

import javax.imageio.ImageIO;
import javax.swing.JFrame;
import javax.swing.JPanel;

import com.umbr3lla.main.state.cards.CardUtils;

public class LoadImage {

	public LoadImage()
	{
		BufferedImage bi=null;
		try {
			bi = ImageIO.read(new File("card_images/base/ac-001.jpg"));
		} catch (IOException e) {
			System.out.println(e);
			e.printStackTrace();
		}
		
		final BufferedImage i = bi;
		
		JFrame f = new JFrame();
		f.setSize(800,800);
		f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		
		
		JPanel p = new JPanel()
		{
			public void paintComponent(Graphics g)
			{
				g.drawImage(i, 0, 0, 800, 800, this);
			}
		};
		
		f.add(p);
		
		f.setVisible(true);
		
		
	}
	
	
	public static void main(String args[])
	{
		new LoadImage();
	}
	
}
